.api-key-container {
	margin-top: 24px;
	display: flex;
	justify-content: center;
	width: 100%;

	.api-key-content {
		width: calc(100% - 30px);
		max-width: 736px;

		.title {
			color: var(--bg-vanilla-100);
			font-size: var(--font-size-lg);
			font-style: normal;
			font-weight: var(--font-weight-normal);
			line-height: 28px; /* 155.556% */
			letter-spacing: -0.09px;
		}

		.subtitle {
			color: var(--bg-vanilla-400);
			font-size: var(--font-size-sm);
			font-style: normal;
			font-weight: var(--font-weight-normal);
			line-height: 20px; /* 142.857% */
			letter-spacing: -0.07px;
		}

		.api-keys-search-add-new {
			display: flex;
			align-items: center;
			gap: 12px;

			padding: 16px 0;

			.add-new-api-key-btn {
				display: flex;
				align-items: center;
				gap: 8px;
			}
		}

		.ant-table-row {
			.ant-table-cell {
				padding: 0;
				border: none;
				background: var(--bg-ink-500);
			}
			.column-render {
				margin: 8px 0 !important;
				border-radius: 6px;
				border: 1px solid var(--bg-slate-500);
				background: var(--bg-ink-400);

				.title-with-action {
					display: flex;
					justify-content: space-between;

					align-items: center;
					padding: 8px;

					.api-key-data {
						display: flex;
						gap: 8px;
						align-items: center;

						.api-key-title {
							display: flex;
							align-items: center;
							gap: 6px;

							.ant-typography {
								color: var(--bg-vanilla-400);
								font-size: var(--font-size-sm);
								font-style: normal;
								font-weight: var(--font-weight-medium);
								line-height: 20px;
								letter-spacing: -0.07px;
							}
						}

						.api-key-value {
							display: flex;
							align-items: center;
							gap: 12px;

							border-radius: 20px;
							padding: 0px 12px;

							background: var(--bg-ink-200);

							.ant-typography {
								color: var(--bg-vanilla-400);
								font-size: var(--font-size-xs);
								font-family: 'Space Mono', monospace;
								font-style: normal;
								font-weight: var(--font-weight-medium);
								line-height: 20px;
								letter-spacing: -0.07px;
							}

							.copy-key-btn {
								cursor: pointer;
							}
						}
					}

					.action-btn {
						display: flex;
						align-items: center;
						gap: 4px;
						cursor: pointer;
					}

					.visibility-btn {
						border: 1px solid rgba(113, 144, 249, 0.2);
						background: rgba(113, 144, 249, 0.1);
					}
				}

				.ant-collapse {
					border: none;

					.ant-collapse-header {
						padding: 0px 8px;

						display: flex;
						align-items: center;
						background-color: #121317;
					}

					.ant-collapse-content {
						border-top: 1px solid var(--bg-slate-500);
					}

					.ant-collapse-item {
						border-bottom: none;
					}

					.ant-collapse-expand-icon {
						padding-inline-end: 0px;
					}
				}

				.api-key-details {
					display: flex;
					align-items: center;
					justify-content: space-between;
					gap: 8px;
					border-top: 1px solid var(--bg-slate-500);
					padding: 8px;

					.api-key-tag {
						width: 14px;
						height: 14px;
						border-radius: 50px;
						background: var(--bg-slate-300);
						display: flex;
						justify-content: center;
						align-items: center;

						.tag-text {
							color: var(--bg-vanilla-400);
							leading-trim: both;
							text-edge: cap;
							font-size: 10px;
							font-style: normal;
							font-weight: var(--font-weight-normal);
							line-height: normal;
							letter-spacing: -0.05px;
						}
					}

					.api-key-created-by {
						margin-left: 8px;
					}

					.api-key-last-used-at {
						display: flex;
						align-items: center;
						gap: 8px;

						.ant-typography {
							color: var(--bg-vanilla-400);
							font-size: var(--font-size-sm);
							font-style: normal;
							font-weight: var(--font-weight-normal);
							line-height: 18px; /* 128.571% */
							letter-spacing: -0.07px;
							font-variant-numeric: lining-nums tabular-nums stacked-fractions
								slashed-zero;
							font-feature-settings: 'dlig' on, 'salt' on, 'cpsp' on, 'case' on;
						}
					}

					.api-key-expires-in {
						font-style: normal;
						font-weight: 400;
						line-height: 18px;

						display: flex;
						align-items: center;
						gap: 8px;

						.dot {
							height: 6px;
							width: 6px;
							border-radius: 50%;
						}

						&.warning {
							color: var(--bg-amber-400);

							.dot {
								background: var(--bg-amber-400);
								box-shadow: 0px 0px 6px 0px var(--bg-amber-400);
							}
						}

						&.danger {
							color: var(--bg-cherry-400);

							.dot {
								background: var(--bg-cherry-400);
								box-shadow: 0px 0px 6px 0px var(--bg-cherry-400);
							}
						}
					}
				}
			}
		}

		.ant-pagination-item {
			display: flex;
			justify-content: center;
			align-items: center;

			> a {
				color: var(--bg-vanilla-400);
				font-variant-numeric: lining-nums tabular-nums slashed-zero;
				font-feature-settings: 'dlig' on, 'salt' on, 'case' on, 'cpsp' on;
				font-size: var(--font-size-sm);
				font-style: normal;
				font-weight: var(--font-weight-normal);
				line-height: 20px; /* 142.857% */
			}
		}

		.ant-pagination-item-active {
			background-color: var(--bg-robin-500);
			> a {
				color: var(--bg-ink-500) !important;
				font-size: var(--font-size-sm);
				font-style: normal;
				font-weight: var(--font-weight-medium);
				line-height: 20px;
			}
		}
	}
}

.api-key-info-container {
	display: flex;
	gap: 12px;
	flex-direction: column;

	.user-info {
		display: flex;
		gap: 8px;
		align-items: center;
		flex-wrap: wrap;

		.user-avatar {
			background-color: lightslategray;
			vertical-align: middle;
		}
	}

	.user-email {
		display: inline-flex;
		align-items: center;
		gap: 12px;
		border-radius: 20px;
		padding: 0px 12px;
		background: var(--bg-ink-200);

		font-family: 'Space Mono', monospace;
	}

	.role {
		display: flex;
		align-items: center;
		gap: 12px;
	}
}

.api-key-modal {
	.ant-modal-content {
		border-radius: 4px;
		border: 1px solid var(--bg-slate-500);
		background: var(--bg-ink-400);
		box-shadow: 0px -4px 16px 2px rgba(0, 0, 0, 0.2);
		padding: 0;

		.ant-modal-header {
			background: none;
			border-bottom: 1px solid var(--bg-slate-500);
			padding: 16px;
		}

		.ant-modal-close-x {
			font-size: 12px;
		}

		.ant-modal-body {
			padding: 12px 16px;
		}

		.ant-modal-footer {
			padding: 16px;
			margin-top: 0;

			display: flex;
			justify-content: flex-end;
		}
	}
}

.api-key-access-role {
	display: flex;

	.ant-radio-button-wrapper {
		font-size: 12px;
		text-transform: capitalize;

		&.ant-radio-button-wrapper-checked {
			color: #fff;
			background: var(--bg-slate-400, #1d212d);
			border-color: var(--bg-slate-400, #1d212d);

			&:hover {
				color: #fff;
				background: var(--bg-slate-400, #1d212d);
				border-color: var(--bg-slate-400, #1d212d);

				&::before {
					background-color: var(--bg-slate-400, #1d212d);
				}
			}

			&:focus {
				color: #fff;
				background: var(--bg-slate-400, #1d212d);
				border-color: var(--bg-slate-400, #1d212d);
			}
		}
	}

	.tab {
		border: 1px solid var(--bg-slate-400);

		flex: 1;

		display: flex;
		justify-content: center;

		&::before {
			background: var(--bg-slate-400);
		}

		&.selected {
			background: var(--bg-slate-400, #1d212d);
		}
	}

	.role {
		display: flex;
		align-items: center;
		gap: 8px;
	}
}

.delete-api-key-modal {
	width: calc(100% - 30px) !important; /* Adjust the 20px as needed */
	max-width: 384px;
	.ant-modal-content {
		padding: 0;
		border-radius: 4px;
		border: 1px solid var(--bg-slate-500);
		background: var(--bg-ink-400);
		box-shadow: 0px -4px 16px 2px rgba(0, 0, 0, 0.2);

		.ant-modal-header {
			padding: 16px;
			background: var(--bg-ink-400);
		}

		.ant-modal-body {
			padding: 0px 16px 28px 16px;

			.ant-typography {
				color: var(--bg-vanilla-400);
				font-size: var(--font-size-sm);
				font-style: normal;
				font-weight: var(--font-weight-normal);
				line-height: 20px;
				letter-spacing: -0.07px;
			}

			.api-key-input {
				margin-top: 8px;
				display: flex;
				gap: 8px;
			}

			.ant-color-picker-trigger {
				padding: 6px;
				border-radius: 2px;
				border: 1px solid var(--bg-slate-400);
				background: var(--bg-ink-300);
				width: 32px;
				height: 32px;

				.ant-color-picker-color-block {
					border-radius: 50px;
					width: 16px;
					height: 16px;
					flex-shrink: 0;

					.ant-color-picker-color-block-inner {
						display: flex;
						justify-content: center;
						align-items: center;
					}
				}
			}
		}

		.ant-modal-footer {
			display: flex;
			justify-content: flex-end;
			padding: 16px 16px;
			margin: 0;

			.cancel-btn {
				display: flex;
				align-items: center;
				border: none;
				border-radius: 2px;
				background: var(--bg-slate-500);
			}

			.delete-btn {
				display: flex;
				align-items: center;
				border: none;
				border-radius: 2px;
				background: var(--bg-cherry-500);
				margin-left: 12px;
			}

			.delete-btn:hover {
				color: var(--bg-vanilla-100);
				background: var(--bg-cherry-600);
			}
		}
	}

	.title {
		color: var(--bg-vanilla-100);
		font-size: var(--font-size-sm);
		font-style: normal;
		font-weight: var(--font-weight-medium);
		line-height: 20px; /* 142.857% */
	}
}

.expiration-selector {
	.ant-select-selector {
		border: 1px solid var(--bg-slate-400) !important;
	}
}

.newAPIKeyDetails {
	display: flex;
	flex-direction: column;
	gap: 8px;
}

.copyable-text {
	display: inline-flex;
	align-items: center;
	gap: 12px;
	border-radius: 20px;
	padding: 0px 12px;
	background: var(--bg-ink-200, #23262e);

	.copy-key-btn {
		cursor: pointer;
	}
}

.lightMode {
	.api-key-container {
		.api-key-content {
			.title {
				color: var(--bg-ink-500);
			}

			.ant-table-row {
				.ant-table-cell {
					background: var(--bg-vanilla-200);
				}

				&:hover {
					.ant-table-cell {
						background: var(--bg-vanilla-200) !important;
					}
				}

				.column-render {
					border: 1px solid var(--bg-vanilla-200);
					background: var(--bg-vanilla-100);

					.ant-collapse {
						border: none;

						.ant-collapse-header {
							background: var(--bg-vanilla-100);
						}

						.ant-collapse-content {
							border-top: 1px solid var(--bg-vanilla-300);
						}
					}

					.title-with-action {
						.api-key-title {
							.ant-typography {
								color: var(--bg-ink-500);
							}
						}

						.api-key-value {
							background: var(--bg-vanilla-200);

							.ant-typography {
								color: var(--bg-slate-400);
							}

							.copy-key-btn {
								cursor: pointer;
							}
						}

						.action-btn {
							.ant-typography {
								color: var(--bg-ink-500);
							}
						}
					}

					.api-key-details {
						border-top: 1px solid var(--bg-vanilla-200);
						.api-key-tag {
							background: var(--bg-vanilla-200);
							.tag-text {
								color: var(--bg-ink-500);
							}
						}

						.api-key-created-by {
							color: var(--bg-ink-500);
						}

						.api-key-last-used-at {
							.ant-typography {
								color: var(--bg-ink-500);
							}
						}
					}
				}
			}
		}
	}

	.delete-api-key-modal {
		.ant-modal-content {
			border: 1px solid var(--bg-vanilla-200);
			background: var(--bg-vanilla-100);

			.ant-modal-header {
				background: var(--bg-vanilla-100);

				.title {
					color: var(--bg-ink-500);
				}
			}

			.ant-modal-body {
				.ant-typography {
					color: var(--bg-ink-500);
				}

				.api-key-input {
					.ant-input {
						background: var(--bg-vanilla-200);
						color: var(--bg-ink-500);
					}
				}
			}

			.ant-modal-footer {
				.cancel-btn {
					background: var(--bg-vanilla-300);
					color: var(--bg-ink-400);
				}
			}
		}
	}

	.api-key-info-container {
		.user-email {
			background: var(--bg-vanilla-200);
		}
	}

	.api-key-modal {
		.ant-modal-content {
			border-radius: 4px;
			border: 1px solid var(--bg-vanilla-200);
			background: var(--bg-vanilla-100);
			box-shadow: 0px -4px 16px 2px rgba(0, 0, 0, 0.2);
			padding: 0;

			.ant-modal-header {
				background: none;
				border-bottom: 1px solid var(--bg-vanilla-200);
				padding: 16px;
			}
		}
	}

	.api-key-access-role {
		.ant-radio-button-wrapper {
			&.ant-radio-button-wrapper-checked {
				color: var(--bg-ink-400);
				background: var(--bg-vanilla-300);
				border-color: var(--bg-vanilla-300);

				&:hover {
					color: var(--bg-ink-400);
					background: var(--bg-vanilla-300);
					border-color: var(--bg-vanilla-300);

					&::before {
						background-color: var(--bg-vanilla-300);
					}
				}

				&:focus {
					color: var(--bg-ink-400);
					background: var(--bg-vanilla-300);
					border-color: var(--bg-vanilla-300);
				}
			}
		}

		.tab {
			border: 1px solid var(--bg-vanilla-300);

			&::before {
				background: var(--bg-vanilla-300);
			}

			&.selected {
				background: var(--bg-vanilla-300);
			}
		}
	}

	.copyable-text {
		background: var(--bg-vanilla-200);
	}
}
